﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Products
{
    public class SelectedProduct
    {
        #region Properties
      
        private Int32 _Id;
        private String _Name;
        private String _Image;
        private String _URL;
        private Int32 _Quantity;
        private Decimal _Price;
        private String _Unit;

        public Int32 Id
        {
            get { return _Id; }
            set { _Id = value; }
        }

        public String Name
        {
            get { return _Name; }
            set { _Name = value; }
        }

        public String Image
        {
            get { return _Image; }
            set { _Image = value; }
        }

        public String URL
        {
            get { return _URL; }
            set { _URL = value; }
        }

        public Int32 Quantity
        {
            get { return _Quantity; }
            set { _Quantity = value; }
        }

        public Decimal Price
        {
            get { return _Price; }
            set { _Price = value; }
        }

        public String Unit
        {
            get { return _Unit; }
            set { _Unit = value; }
        }

        public Decimal SubTotal
        {
            get
            {
                return _Quantity * _Price;
            }
        }

        #endregion

        #region   Constructor

        public SelectedProduct()
        {

        }

        public SelectedProduct(Int32 Id, Int32 Quantity)
        {
            _Id = Id;
            _Quantity = Quantity;
        }

        public SelectedProduct(Int32 Id, String Name, String Unit, Int32 Quantity, Decimal Price)
        {
            _Id = Id;
            _Name = Name;
            _Quantity = Quantity;
            _Price = Price;
            _Unit = Unit;

        }

        public SelectedProduct(Int32 Id, String Name, String Image, String URL, String Unit, Int32 Quantity, Decimal Price)
        {
            _Id = Id;
            _Name = Name; 
            _Image = Image;
            _URL = URL;
            _Quantity = Quantity;
            _Price = Price;
            _Unit = Unit;
           
        }

        #endregion

    }
}
